class CreateDesignerWorkItems < ActiveRecord::Migration
  def self.up
    create_table :designer_work_items do |t|
      t.integer :work_item_id,
        :designer_id,
        :work_item_type_id,
        :stage_id
      t.decimal :billing_area,
        :precision => 8,
        :scale => 2
      t.integer :work_load, :default => 100
      t.integer :provided_percent, :default => 100
      t.integer :guided_percent, :default => 100
      t.integer   :difficulty_num, :default => 100
      t.decimal :should_be_payed,
        :precision => 8,
        :scale => 2,
        :default => 0
      t.text :remark
      t.timestamps
    end
  end

  def self.down
    drop_table :designer_work_items
  end
end
